<?php $this->renderPartial('//common/header'); ?>
<!-- CONTENT CONTAINER -->
<div class="container">
	<div class="content-container row">
		<!-- MAIN CONTENT -->
		<div class="col-md-8 main-content">

			<!-- BLOCK GIỚI THIỆU -->
			<div class="block block-intro">
				<h2 class="title"><a href="<?php echo PIUrl::createUrl('/home/information');?>"><i class="icon icon-intro"></i><?php echo translate("Giới thiệu"); ?></a></h2>
				<div class="content-detail-style">
					<?php echo $this->word_limiter($this->descriptionInfo, 140); ?> <a href="<?php echo PIUrl::createUrl('/home/information');?>" class="view-more"><?php echo translate("Xem thêm"); ?></a></p>
				</div>
			</div>

			<!-- BLOCK THỜI GIAN LÀM VIỆC -->
			<div class="block block-time-work">
				<h2 class="title"><a href="javascript:void(0)"><i class="icon icon-time"></i><?php echo translate("Thời gian làm việc"); ?></a></h2>
				<div class="content-detail">
					<div class="pull-left">
						<p><?php echo $this->arrSystem['text_time']; ?></p>
						<p><i class="icon icon-time-sm"></i>Buổi sáng: <span><?php echo $this->arrSystem['time_morning']; ?></span></p>
						<p><i class="icon icon-time-sm"></i>Buổi chiều: <span><?php echo $this->arrSystem['time_afternoon']; ?></span></p>
					</div>
					<a href="#popup-info-meet" class="btn btn-custom pull-right" id="btn-booking" data-effect="mfp-zoom-in"><?php echo translate("Đặt hẹn trước"); ?></a>
					<div class="clearfix"></div>
				</div>
			</div>

			<!-- BLOCK TIN TỨC NỔI BẬT -->
			<div class="block block-breaking-news">
				<h2 class="title"><a href="<?php echo PIUrl::createUrl('/home/news');?>"><i class="icon icon-breaking-news"></i><?php echo translate("Tin tức nổi bật"); ?> / <span class="more"><?php echo translate("Xem thêm"); ?></span></a></h2>
				<div class="content-detail row">
					<?php if(!empty($arrNews)){ ?>
						<div class="col-md-6 col-sm-6 lg">
							<div class="img-liquid">
								<a href="<?php echo PIUrl::createUrl('/home/newsDetail/', array('alias' => $arrNews[0]->alias));?>"><img src="<?php echo getImage($arrNews[0]->image, 360, 170); ?>"/></a>
							</div>
							<h3 class="title-sm" title="<?php echo $arrNews[0]->name; ?>" ><a href="<?php echo PIUrl::createUrl('/home/newsDetail/', array('alias' => $arrNews[0]->alias));?>"><?php echo $this->word_limiter($arrNews[0]->name, 10);?></a></h3>
							<p><?php echo $this->word_limiter($arrNews[0]->description, 35); ?></p>
							<p class="date-post"><?php echo "Đăng ngày ".date("d/m/Y",$arrNews[0]->created); ?></p>
						</div>
						<div class="col-md-6 col-sm-6">
							<ul class="md">
								<?php for($i=1; $i<count($arrNews); $i++){ ?>
									<li>
										<div class="img-liquid">
											<a href="<?php echo PIUrl::createUrl('/home/newsDetail/', array('alias' => $arrNews[$i]->alias));?>"><img src="<?php echo getImage($arrNews[$i]->image, 170, 78 ); ?>" /></a>
										</div>
										<div class="content-left">
											<h3 class="title-sm" title="<?php echo $arrNews[$i]->name; ?>" ><a href="<?php echo PIUrl::createUrl('/home/newsDetail/', array('alias' => $arrNews[$i]->alias));?>"><?php echo $this->word_limiter($arrNews[$i]->name, 10);?></a></h3>
											<p class="date-post"><?php echo "Đăng ngày ".date("d/m/Y",$arrNews[$i]->created); ?></p>
										</div>
									</li>
								<?php } ?>
							</ul>
						</div>
					<?php } ?>
				</div>
			</div>

			<!-- BLOCK HỖ TRỢ THÔNG TIN -->
			<div class="block block-support-info">
				<h2 class="title"><a href="javascript:void(0)"><i class="icon icon-support-info"></i><?php echo translate("Hỗ trợ thông tin"); ?></a></h2>
				
				<?php if(!empty($arrInformation)){ ?>
					<ul class="row">
						<?php $i =0; ?>
						<?php foreach($arrInformation as $row){ ?>
							<?php $i++; if($i > 2 && $i < 7){ ?>
								<li class="col-md-3 col-sm-3 col-xs-6">
									<div class="img-liquid">
										<a href="<?php echo PIUrl::createUrl('/home/support', array("id"=>$row->id));?>"><img src="<?php echo getImage($row->image, 170, 100); ?>" alt="img" width="170" height="100" /></a>
									</div>
									<a title="<?php echo $row->name; ?>" href="<?php echo PIUrl::createUrl('/home/support', array("id"=>$row->id));?>" class="caption"><?php echo $this->word_limiter($row->name,4); ?></a>
								</li>
							<?php } ?>
						<?php } ?>
					</ul>
				<?php } ?>
			</div>
		</div>

		<!-- SIDEBAR -->
		<div class="col-md-4 sidebar">

			<!-- BLOCK MẪU HỢP ĐỒNG GIAO DỊCH -->
			<?php $this->widget("application.components.widgetDocument"); ?>

			<!-- BLOCK HỎI ĐÁP -->
			<?php $this->widget("application.components.widgetQuestionAnswers"); ?>
			
			<form action="">
				<div class="select">
					<span class="text-selected"></span>
					<i class="icon-select"></i>
					<select id="links" name="links">
						<option value="">Link liên kết</option>
						<?php if(!empty($arrLink)){ ?>
							<?php foreach($arrLink as $row){ ?>
								<option value="<?php echo $row->link; ?>"><?php echo $this->word_limiter($row->title,8); ?></option>
							<?php } ?>
						<?php } ?>
					</select>
				</div>
			</form>
		</div>
	</div>
</div>

<!-- FULL BLOCK HÌNH ẢNH HOẠT ĐỘNG -->
<?php $this->widget("application.components.widgetImages"); ?>

<!-- FULL BLOCK HỖ TRỢ LIÊN KẾT -->
<?php $this->widget("application.components.widgetLinkSupport"); ?>

<div id="push"> </div>
</div>
<script>
	$(document).ready(function(){
		$("#links").change(function(){
			if($(this).val()!="")	window.open($(this).val());
		});
	});
</script>
<?php $this->renderPartial('//common/footer'); ?>